<?php /* Smarty version Smarty-3.1.18, created on 2015-07-10 14:23:58
         compiled from "D:\WWW\yf_qiaqia\Admin\View\Forms\word.html" */ ?>
<?php /*%%SmartyHeaderCode:11305559f28a2769d67-90451848%%*/if(!defined('SMARTY_DIR')) exit('no direct access allowed');
$_valid = $_smarty_tpl->decodeProperties(array (
  'file_dependency' => 
  array (
    'cbb7ff048cfdb58cdf90ed4c37bcc5613d809e9f' => 
    array (
      0 => 'D:\\WWW\\yf_qiaqia\\Admin\\View\\Forms\\word.html',
      1 => 1436509428,
      2 => 'file',
    ),
  ),
  'nocache_hash' => '11305559f28a2769d67-90451848',
  'function' => 
  array (
  ),
  'version' => 'Smarty-3.1.18',
  'unifunc' => 'content_559f28a2ab5a37_18824838',
  'variables' => 
  array (
    '_C' => 0,
    'info' => 0,
    'field' => 0,
    'fd' => 0,
    'form_id' => 0,
    'id' => 0,
    'action' => 0,
  ),
  'has_nocache_code' => false,
),false); /*/%%SmartyHeaderCode%%*/?>
<?php if ($_valid && !is_callable('content_559f28a2ab5a37_18824838')) {function content_559f28a2ab5a37_18824838($_smarty_tpl) {?><!DOCTYPE html>
<html>

	<head>
		<meta charset="utf-8">
		<title></title>
		<link rel="stylesheet" type="text/css" href="<?php echo $_smarty_tpl->tpl_vars['_C']->value['hy_path'];?>
css/amazeui.min.css" />
		<link rel="stylesheet" type="text/css" href="<?php echo $_smarty_tpl->tpl_vars['_C']->value['hy_path'];?>
css/hy.admin.css" />
		
	</head>

	<body>
		<div class="am-g">
			<?php echo $_smarty_tpl->getSubTemplate ('../Common/hy_header.html', $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array(), 0);?>

			<style>
				.yf-form {
					float: left !important;
				}
			</style>
			<div class="am-u-md-8 am-u-end">
				<form class="am-form am-form-horizontal hy-js-form">
					<div class="am-form-group">
						<label for="user-name" class="am-u-sm-3 am-form-label">字段</label>
						<div class="am-u-sm-6 yf-form">
							<select name="fields_id" <?php if ($_smarty_tpl->tpl_vars['info']->value['fields_id']!='') {?> disabled <?php }?>>
								<option value="0">请选择字段</option>
								<?php  $_smarty_tpl->tpl_vars['fd'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['fd']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['field']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
foreach ($_from as $_smarty_tpl->tpl_vars['fd']->key => $_smarty_tpl->tpl_vars['fd']->value) {
$_smarty_tpl->tpl_vars['fd']->_loop = true;
?>
								<option value="<?php echo $_smarty_tpl->tpl_vars['fd']->value['id'];?>
" <?php if ($_smarty_tpl->tpl_vars['info']->value['fields_id']==$_smarty_tpl->tpl_vars['fd']->value['id']) {?> selected <?php }?>><?php echo $_smarty_tpl->tpl_vars['fd']->value['name'];?>
----<?php echo $_smarty_tpl->tpl_vars['fd']->value['data'];?>
----<?php echo $_smarty_tpl->tpl_vars['fd']->value['type'];?>
</option>
								<?php } ?>
							</select>
						</div>
					</div>
					<div class="am-form-group">
						<label for="user-name" class="am-u-sm-3 am-form-label">字段类型</label>
						<div class="am-u-sm-6 yf-form">
							<select name="type" id="type_change">
								<option value="0">请选择字段类型</option>
								<option value="int" <?php if ($_smarty_tpl->tpl_vars['info']->value['type']=='int') {?> selected <?php }?>>数值---int</option>
								<option value="varchar" <?php if ($_smarty_tpl->tpl_vars['info']->value['type']=='varchar') {?> selected <?php }?>>小文本---varchar</option>
								<option value="text" <?php if ($_smarty_tpl->tpl_vars['info']->value['type']=='text') {?> selected <?php }?>>大文本---text</option>
							</select>
						</div>
					</div>
					<div class="am-form-group">
						<label for="user-name" class="am-u-sm-3 am-form-label">字段大小</label>
						<div class="am-u-sm-6 yf-form">
							<input type="text" name="type_size" id="type_size" value="<?php echo $_smarty_tpl->tpl_vars['info']->value['type_size'];?>
" placeholder="请先选择字段类型">
						</div>
					</div>
					<div class="am-form-group">
						<label for="user-intro" class="am-u-sm-3 am-form-label">是否必填</label>
						<div class="am-u-sm-6 yf-form">
							<div class="am-btn-group" data-am-button="">
								<label class="am-btn am-btn-default am-btn-xs <?php if ($_smarty_tpl->tpl_vars['info']->value['status']==''||$_smarty_tpl->tpl_vars['info']->value['status']==0) {?>am-active<?php }?>">
									<input type="radio" name="status" value="0" <?php if ($_smarty_tpl->tpl_vars['info']->value['status']==''||$_smarty_tpl->tpl_vars['info']->value['status']==0) {?>checked="checked"<?php }?> id="option1"> 否
								</label>
								<label class="am-btn am-btn-default am-btn-xs <?php if ($_smarty_tpl->tpl_vars['info']->value['status']==1) {?>am-active<?php }?>">
									<input type="radio" name="status" value="1" <?php if ($_smarty_tpl->tpl_vars['info']->value['status']==1) {?>checked="checked"<?php }?> id="option2"> 是
								</label>
							</div>
						</div>
					</div>
					<div class="am-form-group">
						<label for="user-intro" class="am-u-sm-3 am-form-label">显示列表</label>
						<div class="am-u-sm-6 yf-form">
							<div class="am-btn-group" data-am-button="">
								<label class="am-btn am-btn-default am-btn-xs <?php if ($_smarty_tpl->tpl_vars['info']->value['is_list']==''||$_smarty_tpl->tpl_vars['info']->value['is_list']==0) {?>am-active<?php }?>">
									<input type="radio" name="is_list" value="0" <?php if ($_smarty_tpl->tpl_vars['info']->value['is_list']==''||$_smarty_tpl->tpl_vars['info']->value['is_list']==0) {?>checked="checked"<?php }?> id="op1"> 否
								</label>
								<label class="am-btn am-btn-default am-btn-xs <?php if ($_smarty_tpl->tpl_vars['info']->value['is_list']==1) {?>am-active<?php }?>">
									<input type="radio" name="is_list" value="1" <?php if ($_smarty_tpl->tpl_vars['info']->value['is_list']==1) {?>checked="checked"<?php }?> id="op2"> 是
								</label>
							</div>
						</div>
					</div>
					<div class="am-form-group">
						<input type="hidden" name="form_id" value="<?php echo $_smarty_tpl->tpl_vars['form_id']->value;?>
">
						<input type="hidden" name="id" value="<?php echo $_smarty_tpl->tpl_vars['id']->value;?>
">
						<div class="am-u-sm-6 am-u-sm-push-3">
							<button type="button" class="am-btn am-btn-primary hy-js-submit">提交</button>
						</div>
					</div>
				</form>
			</div>
		</div>
		<?php echo $_smarty_tpl->getSubTemplate ('../Common/hy_footer.html', $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array(), 0);?>

		<script type="text/javascript">
			$(function(){
				$('#type_change').change(function(){
					var type = $(this).val();
					if(type == 0)
					{
						$('#type_size').val('');
					}
					if(type == 'int')
					{
						$('#type_size').val(11);
					}
					if(type == 'varchar')
					{
						$('#type_size').val(255);
					}
					if(type == 'text')
					{
						$('#type_size').val(0);
					}
				});
			});
			hy_submit('index.php?g=admin&m=forms&a=<?php echo $_smarty_tpl->tpl_vars['action']->value;?>
');
		</script>
	</body>

</html><?php }} ?>
